<script setup>
import { reactive } from 'vue';

defineOptions({ name: 'KeywordChangePriceModal' });

const emit = defineEmits(['confirm']);
const visible = defineModel('visible', { default: false });

const model = reactive({
  price: ''
});

function confirm() {
  emit('confirm');
}
</script>

<template>
  <ElDialog v-model="visible" title="关键词改价" class="w-500px">
    <div class="flex-col items-center justify-center">
      <ElForm ref="formRef" :model="model" label-position="right" :label-width="80">
        <ElFormItem :label="$t('page.operations.bid')" prop="price">
          <ElInput v-model="model.price" />
        </ElFormItem>
      </ElForm>
      <ElSpace :size="10">
        <ElButton type="primary" @click="confirm">{{ $t('page.operations.startHaggling') }}</ElButton>
      </ElSpace>
    </div>
  </ElDialog>
</template>
